package com.atguigu.jxc.dao;

import com.atguigu.jxc.entity.PurchaseList;
import com.atguigu.jxc.entity.PurchaseVO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 * @author WZhaokang
 * @date 2020/12/29 13:53
 */
@Repository
public interface PurchaseListDao {

    int save(PurchaseList purchaseList);

    List<PurchaseList> list(@Param("purchaseNumber") String purchaseNumber, @Param("supplierId") Integer supplierId, @Param("state") Integer state,@Param("sTime") String sTime, @Param("eTime") String eTime);

    void deleteByPurchaseListId(@Param("purchaseListId") Integer purchaseListId);

    PurchaseList selectByPurchaseListId(@Param("purchaseListId") Integer purchaseListId);

    void updateState(@Param("purchaseListId") Integer purchaseListId,@Param("state") Integer state);

    List<PurchaseList> selectByTime(@Param("sTime") String sTime,@Param("eTime") String eTime);

    List<PurchaseVO> findList(@Param("sTime") String sTime, @Param("eTime") String eTime, @Param("goodsTypeId") Integer goodsTypeId, @Param("codeOrName") String codeOrName);
}
